<?php

        function getNeighborsQuery($id){
		$query = "
			SELECT CASE
			   WHEN (Edges.Start=".$id.") THEN Edges.End
			   WHEN (Edges.End=".$id.") THEN Edges.Start
			   ELSE NULL
			   END as Neighbors
			FROM Edges
			WHERE Edges.Start=".$id." OR Edges.End=".$id."
		";
		return $query;
        }
?>

